<?php
namespace app\admin\validate;
use think\Controller;
use think\facade\Session;

class UserValidate extends Controller{
    public function __construct()
    {
        parent::__construct();
        # 判断管理员的登录状态
        if (!session::get('userinfo')) {
            $this->error('请先登录...', url('admin/user/logion'));
        }
    }
}